Audio signals are frequently communicated in a digital format as a sequence of digital numbers, as in common consumer products such as the Compact Disc player, or in mobile phones, which convert analog audio to digital audio data streams for transmission over mobile telephone networks.
It is often necessary to combine two digital audio data streams to provide a combined input audio data signal. This process of adding multiple audio data streams is commonly called “mixing.” In order to mix or add together two or more input digital audio data streams, the input audio data streams must be at the same sample rate, or the resulting audio sum will be distorted.
However, in many cases where two or more digital audio data streams are to be mixed, the incoming digital audio data streams are not at the same sample rate. The original sample rate of the audio may have been generated or recorded at different sample rates, such as 48,000 samples per second for high fidelity audio, and 8,000 samples per second for telephone quality audio.
Even if the original audio sources were generated at the same nominal sample rate, the crystal oscillators commonly used for clocking audio data have some error or drift. Usually inexpensive crystal oscillators may drift by 1 part in 10,000 or 100 parts per million (PPM).
Therefore, a process known as asynchronous sample rate conversion can be performed on one or more of the input data streams. Asynchronous sample rate conversion converts the sample rate of a first data stream to the sample rate of another data stream to be mixed with the first data stream.
It is also possible to mix two audio data streams by converting the data streams to analog voltages using two Digital-to-Analog convertors (DACs), and then summing together the two analog signals. However, the processing and time costs of using the two DACs can be greater than the processing and time costs of performing the sample rate conversion operation in the digital domain. If done properly, the quality of digital sample rate conversion will exceed the quality of summation of two input signals in the analog domain.
What is needed is a system for mixing two audio data streams having independent and asynchronous sample rates in an efficient manner.